<h2>Visar alla branscher </h2>

<table class='admin_datatable'>
	<thead>
		<tr><td>Bransch</td><td>Händelse</td></tr>
	</thead>
	<tbody>
	<?php foreach($branches as $mb): ?>
		<tr>
			<td>
				<strong><?php echo $mb->name;?></strong>
			</td>
			<td>
				<a href='/admin/branches/remove/<?php echo $mb->id;?>' class='delete' onclick='return confirm("Vill du verkligen ta bort branschen?");'>Ta bort</a>
			</td>
		</tr>
		<?php foreach($mb->children as $sb) : ?>
		<tr>
			<td class='indent'>
				<?php echo $sb->name;?>
			</td>
			<td>
				<a href='/admin/branches/remove/<?php echo $sb->id;?>' class='delete' onclick='return confirm("Vill du verkligen ta bort branschen?");'>Ta bort</a>
			</td>
		</tr>
		<?php endforeach;?>
	<?php endforeach; ?>
	</tbody>
</table>